<?php
include '../common/autoload.php';
if(!isset($_SESSION['memberID'])){
    echo "<script>window.location.href='/';</script>";
    exit;
}

$btime3 = date('Y-m-d').' 00:00:00';
$etime3 = date('Y-m-d H:i:s');
$salerid = abs($_GET['salerid']);
$s = SoapInit::GetSoapInside();
$type = abs($_GET['t']);//景区产品1线路产品2
$orderNum = '';
//$r = $s->Order_Globle_Search("{$salerid}","","","","","","","","","","$btime3","$etime3","$orderNum","","","1","","","3","1","0","20",0);
$r = $s->Order_Globle_Search("{$salerid}","","","","","","","","","","$btime3","$etime3", "$orderNum","", "", "", "", "", "", "1", "0", "15", "0", "0", "", "0", "", "0", "", "", "", "0", "0", "0");

$htmlList = '';
$prod_title = urldecode($_GET['title']);
$orderLists =simplexml_load_string($r);
if(!count($orderLists)) {
    $htmlList = '今日没有订单';
}
else {
    foreach ( $orderLists ->Rec as $list ) {
        $orderNum  = $list->UUordernum;
        $ttype     = $list->UUttitle;
        $orderName = $list->UUordername;
        $orderTel  = $list->UUordertel;
        $tnum      = $list->UUtnum;
        $UUdtime   = substr($list->UUdtime,10,6);
        $htmlList .=<<< HTML
    <li>{$UUdtime}{$orderName}&nbsp;{$tnum}张{$ttype}<a href="morder.html?on={$orderNum}&t={$type}">查看</a></li>
HTML;
    }
}

?>
<html>
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <title>验票系统--今日已验证订单</title>
    <link rel="stylesheet" href="css/gumby.css">
    <link rel="stylesheet" href="css/public.css">
</head>
<body>
<div class="header">
    <h1 class="title">今日已验证订单<a class="exit" href="javascript:history.go(-1);">返回</a></h1>
</div>
<div class="container">
    <div class="row">
        <div class="twelve columns">
            <p class="sub_title">产品名称:<?=$prod_title?></p>
            <ul class="square mt1"><?=$htmlList?></ul>
        </div>
    </div>
</div>
<div class="footer">
    <h1 class="title">&copy;先行旅游 版权所有</h1>
</div>
</body>
</html>